#version 450 compatibility


//视口矩阵
layout(std140, binding = 0) buffer Buf_modelTranform {
    mat4 TranformMat[];
};


layout(location = 0) in vec4 vPosition;
layout(location = 1) in vec4 vNormal;
layout(location = 2) in vec4 vTCoord;

//输出到下一阶段
layout(location = 1) out vec4 Normal;
layout(location = 2) out vec2 TCoord;

void main(){
    Normal = vNormal;
    gl_Position = gl_ProjectionMatrix * ((gl_ModelViewMatrix * TranformMat[gl_InstanceID]) * vPosition);
    //gl_Position = gl_ProjectionMatrix * ((gl_ModelViewMatrix * ModelTranformMat) * vPosition);
}



